//
//  DCLoginViewController.m
//  Dearcare
//
//  Created by 劳景醒 on 2018/10/10.
//  Copyright © 2018年 laojingxing. All rights reserved.
//

#import "DCLoginHomePageViewController.h"
#import "DCLoginViewController.h"

@interface DCLoginHomePageViewController ()
@property (weak, nonatomic) IBOutlet NSLayoutConstraint *imageViewTop;
@property (weak, nonatomic) IBOutlet UIImageView *logoImageView;
@property (weak, nonatomic) IBOutlet UILabel *appNameLabel;
@property (weak, nonatomic) IBOutlet UIButton *registerButton;
@property (weak, nonatomic) IBOutlet UIButton *loginButton;

@end

@implementation DCLoginHomePageViewController

- (void)viewDidLoad {
    [super viewDidLoad];
    // Do any additional setup after loading the view from its nib.
    
    self.view.backgroundColor = kMainColor;
    [self _initSubViews];
}

- (void)viewWillAppear:(BOOL)animated {
    [self.navigationController setNavigationBarHidden:YES animated:animated];
    [super viewWillAppear:animated];
}

- (void)viewWillDisappear:(BOOL)animated {
    [self.navigationController setNavigationBarHidden:NO animated:animated];
    [super viewWillDisappear:animated];
}

- (void)_initSubViews {
    self.registerButton.backgroundColor = [UIColor clearColor];
    self.registerButton.layer.cornerRadius = self.registerButton.height / 2.0;
    self.registerButton.layer.masksToBounds = YES;
    self.registerButton.layer.borderColor = [UIColor whiteColor].CGColor;
    self.registerButton.layer.borderWidth = 1.0;
    
    [self.loginButton buttonBorderWidth:1.0 borderColor:[UIColor whiteColor] cornerRadius:self.loginButton.height / 2.0];
    self.loginButton.backgroundColor = [UIColor whiteColor];
}

- (IBAction)registerAction:(id)sender {
}

- (IBAction)loginAction:(id)sender {
    DCLoginViewController *vc = [[DCLoginViewController alloc] init];
    [self.navigationController pushViewController:vc animated:YES];
}

- (void)didReceiveMemoryWarning {
    [super didReceiveMemoryWarning];
    // Dispose of any resources that can be recreated.
}

/*
#pragma mark - Navigation

// In a storyboard-based application, you will often want to do a little preparation before navigation
- (void)prepareForSegue:(UIStoryboardSegue *)segue sender:(id)sender {
    // Get the new view controller using [segue destinationViewController].
    // Pass the selected object to the new view controller.
}
*/

@end
